package com.tungse.study.mixed_model;

/**
 * 减法表达式
 * @author Tungse
 */
public class SubExpression implements Expression{
    Expression left;
    Expression right;
    public SubExpression(Expression left, Expression right) {
        this.left = left;
        this.right = right;
    }

    @Override
    public double getValue() {
        return left.getValue() - right.getValue();
    }
}
